<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"
            "http://www.w3.org/TR/REC-html40/loose.dtd">
<HTML>
<HEAD>



<META http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<META name="GENERATOR" content="hevea 1.08">
<LINK rel="stylesheet" type="text/css" href="umsroot.css">
<TITLE>
Syntax
</TITLE>
</HEAD>
<BODY >
<A HREF="umsroot095.html"><IMG SRC ="previous_motif.gif" ALT="Previous"></A>
<A HREF="umsroot093.html"><IMG SRC ="contents_motif.gif" ALT="Up"></A>
<A HREF="umsroot097.html"><IMG SRC ="next_motif.gif" ALT="Next"></A>
<HR>

<H2 CLASS="section"><A NAME="htoc220">16.3</A>&nbsp;&nbsp;Syntax</H2>
The most general attributed variable syntax is
<BLOCKQUOTE CLASS="quote">
<I>Var</I>{<I>Name</I><SUB>1</SUB>:<I>Attr</I><SUB>1</SUB>, <I>Name</I><SUB>2</SUB>:<I>Attr</I><SUB>2</SUB>, &hellip;, <I>Name</I><SUB><I>n</I></SUB>:<I>Attr</I><SUB><I>n</I></SUB>}
</BLOCKQUOTE>
where the syntax of <I>Var</I> is like that of a variable,
<I><I>Name</I></I><SUB><I><I>i</I></I></SUB>
are attribute names and
<I><I>Attr</I></I><SUB><I><I>i</I></I></SUB>
are the values of the corresponding attributes.

The expression <B>Var{Attr}</B> is a shorthand for <B>Var{Module:Attr}</B>
where <B>Module</B> is the current module name.
The former is called <I>unqualified</I> and the latter <I>qualified</I>
attribute specification.
<A NAME="@default901"></A>
<A NAME="@default902"></A>
<A NAME="@default903"></A>
As the attribute name is usually identical with the source module name,
all occurrences of an attributed variable in the source module may use the unqualified
specification.<BR>
<BR>
If there are several occurrences of the same attributed variable in a single term,
only one occurrence is written with the attribute,
the others just refer to the variable's name,
e.g.
<BLOCKQUOTE CLASS="quote"><PRE CLASS="verbatim">
p(X, X{attr:Attr})
</PRE></BLOCKQUOTE>
or
<BLOCKQUOTE CLASS="quote"><PRE CLASS="verbatim">
p(X{attr:Attr}, X)
</PRE></BLOCKQUOTE>
both describe the same term, which has two occurrences of a single attributed variable
with attribute <TT>attr:Attr</TT>.
The following is a syntax error (even when the attributes are identical):
<BLOCKQUOTE CLASS="quote"><PRE CLASS="verbatim">
p(X{attr:Attr}, X{attr:Attr})
</PRE></BLOCKQUOTE>
<HR>
<A HREF="umsroot095.html"><IMG SRC ="previous_motif.gif" ALT="Previous"></A>
<A HREF="umsroot093.html"><IMG SRC ="contents_motif.gif" ALT="Up"></A>
<A HREF="umsroot097.html"><IMG SRC ="next_motif.gif" ALT="Next"></A>
</BODY>
</HTML>
